<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<form action="/findPage" method="get">

    <input type="text" name="name" placeholder="输入姓名">
    <input type="text" name="dname" placeholder="输入部门">
    <input type="submit" value="提交">
    <table>
        <tr>
            <td>id</td>
            <td>name</td>
            <td>sex</td>
            <td>address</td>
            <td>dname</td>
            <td>操作</td>
        </tr>
        <tr th:each="person:${persons.records}">
            <td th:text="${person.id}"></td>
            <td th:text="${person.name}"></td>
            <td th:text="${person.sex}"></td>
            <td th:text="${person.address}"></td>
            <td th:text="${person.dname}"></td>
            <td>
<!--                <a th:href="@{/del(id=${student.id})}">删除</a>-->
                <a th:href="@{/delete(id=${person.id})}">删除</a>
            </td>
        </tr>
    </table>

    <a href="/findPage?current=1">首页</a>
    <a th:href="@{/findPage(current=${persons.getCurrent()-1})}">上一页</a>
    <a th:href="@{/findPage(current=${persons.getCurrent()+1})}">下一页</a>
    <a th:href="@{/findPage(current=${persons.getPages()})}">尾页</a>
</form>

</body>
</html>